package com.ffyc.resale.component;

import com.ffyc.resale.dao.ChatDao;
import com.ffyc.resale.web.WebSocketServer;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

import javax.annotation.PostConstruct;

@Component
public class WebSocketComponent {
    @Autowired
    private ChatDao chatDao;

    @PostConstruct
    public void init() {
        WebSocketServer.setChatDao(chatDao);
    }
}